package com.newtouch.xcd.admin.mft.controller;
import com.google.common.collect.Lists;

import com.newtouch.xcd.cms.to.crm.*;
import com.newtouch.xcd.common.to.CommonResult;
import com.newtouch.xcd.mft.vo.CrmQueryDetailsOfFamilyTrustTransactionsReq;
import com.newtouch.xcd.mft.vo.MftQueryAssetAllocationReq;
import com.newtouch.xcd.mft.vo.MftQueryAssetAllocationRsp;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.validation.BindingResult;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;
import javax.validation.Valid;
import java.util.ArrayList;
import java.util.List;

@Slf4j
@CrossOrigin
@RestController
@Api(tags = "CrmController", description = "2.6新财道crm模块")
@RequestMapping("/crm")
public class CrmController {

    /**
     * 2.2.06我的信托-查询交易明细
     *
     * @param request
     * @return
     */
    @ApiOperation(value = "查询家族信托交易明细")
    @PostMapping(value = "/queryDetailsOfFamilyTrustTransactions")
    public Object queryDetailsOfFamilyTrustTransactions(@Valid @RequestBody CrmQueryDetailsOfFamilyTrustTransactionsReq req, BindingResult result, HttpServletRequest request) {
        CrmData rsp = new CrmData();
        rsp.setTrustAccountBalance("1,480,728.79");
        rsp.setReportTime("2020-06-02 16:51:00");

        CrmIncomeItem crmIncomeItem = new CrmIncomeItem();
        crmIncomeItem.setEquityInvestmentIncome("0.00");
        crmIncomeItem.setFinancialIncome("110,728.79");
        crmIncomeItem.setInitialAdditionalTrustProperty("10,370,000.00");
        crmIncomeItem.setOtherIncome("0.00");
        crmIncomeItem.setTotal("10,480,728.79");

        rsp.setIncomeItem(crmIncomeItem);

        CrmAssetAllocationItem crmAssetAllocationItem = new CrmAssetAllocationItem();
        CrmAssetAllocationDetailItem crmAssetAllocationDetailItem = new CrmAssetAllocationDetailItem();
        crmAssetAllocationDetailItem.setTotalConfiguration("1,000,000.00");
        crmAssetAllocationDetailItem.setTotalGrossReceipts("72,591.80");
        crmAssetAllocationDetailItem.setTotalTotalPrincipalRecovered("1,000,000.00");

        List<CrmAssetAllocationProductItem> crmAssetAllocationProductItems = new ArrayList<>();
        CrmAssetAllocationProductItem crmAssetAllocationProductItem = new CrmAssetAllocationProductItem();//1
        crmAssetAllocationProductItem.setShareConfirmationDate("2018-02-08");
        crmAssetAllocationProductItem.setAmount("630,000.00");
        crmAssetAllocationProductItem.setConfigurationCategory("基金类");
        crmAssetAllocationProductItem.setCustomerProductCategory("现金管理类");
        crmAssetAllocationProductItem.setEarnedIncome("45,732.83");
        crmAssetAllocationProductItem.setProductInformation("");
        crmAssetAllocationProductItem.setProject("新财道稳健增益8号契约型私募基金-第2期");
        crmAssetAllocationProductItem.setRecoverPrincipal("630,000.00");
        crmAssetAllocationProductItem.setRemark("到期");

        List<CrmAssetAllocationProductIncomeItem> crmAssetAllocationProductIncomeItems = new ArrayList<>();
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem1 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem1.setBenefitDate("2018-03-20");
        crmAssetAllocationProductIncomeItem1.setBenefitAmount("6,351.78");
        crmAssetAllocationProductIncomeItem1.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems.add(crmAssetAllocationProductIncomeItem1);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem2 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem2.setBenefitDate("2018-06-20");
        crmAssetAllocationProductIncomeItem2.setBenefitAmount("14,609.10");
        crmAssetAllocationProductIncomeItem2.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems.add(crmAssetAllocationProductIncomeItem2);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem3 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem3.setBenefitDate("2018-09-20");
        crmAssetAllocationProductIncomeItem3.setBenefitAmount("14,609.10");
        crmAssetAllocationProductIncomeItem3.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems.add(crmAssetAllocationProductIncomeItem3);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem4 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem4.setBenefitDate("2018-10-10");
        crmAssetAllocationProductIncomeItem4.setBenefitAmount("3,175.89");
        crmAssetAllocationProductIncomeItem4.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems.add(crmAssetAllocationProductIncomeItem4);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem5 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem5.setBenefitDate("2018-11-23");
        crmAssetAllocationProductIncomeItem5.setBenefitAmount("6,986.96");
        crmAssetAllocationProductIncomeItem5.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems.add(crmAssetAllocationProductIncomeItem5);

        crmAssetAllocationProductItem.setIncomeList(crmAssetAllocationProductIncomeItems);
        crmAssetAllocationProductItems.add(crmAssetAllocationProductItem);

        CrmAssetAllocationProductItem crmAssetAllocationProductItem2 = new CrmAssetAllocationProductItem();//2
        crmAssetAllocationProductItem2.setShareConfirmationDate("2018-02-08");
        crmAssetAllocationProductItem2.setAmount("370,000.00");
        crmAssetAllocationProductItem2.setConfigurationCategory("基金类");
        crmAssetAllocationProductItem2.setCustomerProductCategory("现金管理类");
        crmAssetAllocationProductItem2.setEarnedIncome("26,858.97");
        crmAssetAllocationProductItem2.setProductInformation("");
        crmAssetAllocationProductItem2.setProject("新财道稳健增益8号契约型私募基金-第2期");
        crmAssetAllocationProductItem2.setRecoverPrincipal("370,000.00");
        crmAssetAllocationProductItem2.setRemark("到期");

        List<CrmAssetAllocationProductIncomeItem> crmAssetAllocationProductIncomeItems2 = new ArrayList<>();
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem6 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem6.setBenefitDate("2018-03-20");
        crmAssetAllocationProductIncomeItem6.setBenefitAmount("3,730.41");
        crmAssetAllocationProductIncomeItem6.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems2.add(crmAssetAllocationProductIncomeItem6);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem7 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem7.setBenefitDate("2018-06-20");
        crmAssetAllocationProductIncomeItem7.setBenefitAmount("8,579.95");
        crmAssetAllocationProductIncomeItem7.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems2.add(crmAssetAllocationProductIncomeItem7);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem8 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem8.setBenefitDate("2018-09-20");
        crmAssetAllocationProductIncomeItem8.setBenefitAmount("8,579.95");
        crmAssetAllocationProductIncomeItem8.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems2.add(crmAssetAllocationProductIncomeItem8);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem9 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem9.setBenefitDate("2018-10-10");
        crmAssetAllocationProductIncomeItem9.setBenefitAmount("1,865.21");
        crmAssetAllocationProductIncomeItem9.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems2.add(crmAssetAllocationProductIncomeItem9);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem10 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem10.setBenefitDate("2018-11-23");
        crmAssetAllocationProductIncomeItem10.setBenefitAmount("4,103.45");
        crmAssetAllocationProductIncomeItem10.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems2.add(crmAssetAllocationProductIncomeItem10);

        crmAssetAllocationProductItem2.setIncomeList(crmAssetAllocationProductIncomeItems2);
        crmAssetAllocationProductItems.add(crmAssetAllocationProductItem2);

        crmAssetAllocationDetailItem.setAssetAllocationProductList(crmAssetAllocationProductItems);

        crmAssetAllocationItem.setAssetAllocationMaturity(crmAssetAllocationDetailItem);
        crmAssetAllocationItem.setTotalConfiguration("10,000,000.00");
        crmAssetAllocationItem.setTotalGrossReceipts("110,728.79");
        crmAssetAllocationItem.setTotalTotalPrincipalRecovered("1,000,000.00");

        CrmAssetAllocationDetailItem crmAssetAllocationDetailItem2 = new CrmAssetAllocationDetailItem();
        crmAssetAllocationDetailItem2.setTotalConfiguration("9,000,000.00");
        crmAssetAllocationDetailItem2.setTotalGrossReceipts("38,136.99");
        crmAssetAllocationDetailItem2.setTotalTotalPrincipalRecovered("0.00");

        List<CrmAssetAllocationProductItem> crmAssetAllocationProductItems2 = new ArrayList<>();
        CrmAssetAllocationProductItem crmAssetAllocationProductItem3 = new CrmAssetAllocationProductItem();//1
        crmAssetAllocationProductItem3.setShareConfirmationDate("2019-12-26");
        crmAssetAllocationProductItem3.setAmount("3,000,000.00");
        crmAssetAllocationProductItem3.setConfigurationCategory("信托类");
        crmAssetAllocationProductItem3.setCustomerProductCategory("固定收益类");
        crmAssetAllocationProductItem3.setEarnedIncome("0.00");
        crmAssetAllocationProductItem3.setProductInformation("");
        crmAssetAllocationProductItem3.setProject("长安信托鑫苑中国公司债投资集合资金信托计划");
        crmAssetAllocationProductItem3.setRecoverPrincipal("0.00");
        crmAssetAllocationProductItem3.setRemark("存续");

        List<CrmAssetAllocationProductIncomeItem> crmAssetAllocationProductIncomeItems3 = new ArrayList<>();
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem11 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem11.setBenefitDate("2020-12-26");
        crmAssetAllocationProductIncomeItem11.setBenefitAmount("259,250.00");
        crmAssetAllocationProductIncomeItem11.setArriveFlag("0");
        crmAssetAllocationProductIncomeItems3.add(crmAssetAllocationProductIncomeItem11);

        crmAssetAllocationProductItem3.setIncomeList(crmAssetAllocationProductIncomeItems3);
        crmAssetAllocationProductItems2.add(crmAssetAllocationProductItem3);

        CrmAssetAllocationProductItem crmAssetAllocationProductItem4 = new CrmAssetAllocationProductItem();//2
        crmAssetAllocationProductItem4.setShareConfirmationDate("2019-11-21");
        crmAssetAllocationProductItem4.setAmount("6,000,000.00");
        crmAssetAllocationProductItem4.setConfigurationCategory("其他类");
        crmAssetAllocationProductItem4.setCustomerProductCategory("其他类");
        crmAssetAllocationProductItem4.setEarnedIncome("38,136.99");
        crmAssetAllocationProductItem4.setProductInformation("");
        crmAssetAllocationProductItem4.setProject("浙江途韩进出口有限公司");
        crmAssetAllocationProductItem4.setRecoverPrincipal("0.00");
        crmAssetAllocationProductItem4.setRemark("存续");

        List<CrmAssetAllocationProductIncomeItem> crmAssetAllocationProductIncomeItems4 = new ArrayList<>();
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem12 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem12.setBenefitDate("2019-12-20");
        crmAssetAllocationProductIncomeItem12.setBenefitAmount("38,136.99");
        crmAssetAllocationProductIncomeItem12.setArriveFlag("1");
        crmAssetAllocationProductIncomeItems4.add(crmAssetAllocationProductIncomeItem12);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem13 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem13.setBenefitDate("2020-06-20");
        crmAssetAllocationProductIncomeItem13.setBenefitAmount("240,657.53");
        crmAssetAllocationProductIncomeItem13.setArriveFlag("0");
        crmAssetAllocationProductIncomeItems4.add(crmAssetAllocationProductIncomeItem13);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem14 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem14.setBenefitDate("2020-12-20");
        crmAssetAllocationProductIncomeItem14.setBenefitAmount("240,657.53");
        crmAssetAllocationProductIncomeItem14.setArriveFlag("0");
        crmAssetAllocationProductIncomeItems4.add(crmAssetAllocationProductIncomeItem14);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem15 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem15.setBenefitDate("2021-06-20");
        crmAssetAllocationProductIncomeItem15.setBenefitAmount("239,342.47");
        crmAssetAllocationProductIncomeItem15.setArriveFlag("0");
        crmAssetAllocationProductIncomeItems4.add(crmAssetAllocationProductIncomeItem15);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem16 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem16.setBenefitDate("2021-12-20");
        crmAssetAllocationProductIncomeItem16.setBenefitAmount("240,657.53");
        crmAssetAllocationProductIncomeItem16.setArriveFlag("0");
        crmAssetAllocationProductIncomeItems4.add(crmAssetAllocationProductIncomeItem16);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem17 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem17.setBenefitDate("2022-06-20");
        crmAssetAllocationProductIncomeItem17.setBenefitAmount("239,342.47");
        crmAssetAllocationProductIncomeItem17.setArriveFlag("0");
        crmAssetAllocationProductIncomeItems4.add(crmAssetAllocationProductIncomeItem17);
        CrmAssetAllocationProductIncomeItem crmAssetAllocationProductIncomeItem18 = new CrmAssetAllocationProductIncomeItem();
        crmAssetAllocationProductIncomeItem18.setBenefitDate("2022-11-21");
        crmAssetAllocationProductIncomeItem18.setBenefitAmount("202,520.55");
        crmAssetAllocationProductIncomeItem18.setArriveFlag("0");
        crmAssetAllocationProductIncomeItems4.add(crmAssetAllocationProductIncomeItem18);

        crmAssetAllocationProductItem4.setIncomeList(crmAssetAllocationProductIncomeItems4);
        crmAssetAllocationProductItems2.add(crmAssetAllocationProductItem4);

        crmAssetAllocationDetailItem2.setAssetAllocationProductList(crmAssetAllocationProductItems2);

        crmAssetAllocationItem.setAssetAllocationStoragePeriod(crmAssetAllocationDetailItem2);

        rsp.setAssetAllocation(crmAssetAllocationItem);

        CrmCreditInsuranceFundOccupiedFundItem crmCreditInsuranceFundOccupiedFundItem = new CrmCreditInsuranceFundOccupiedFundItem();
        crmCreditInsuranceFundOccupiedFundItem.setTotal("0.00");
        List<CrmCreditInsuranceFundOccupiedFundDetailItem> crmCreditInsuranceFundOccupiedFundDetailItems = new ArrayList<>();
//        CrmCreditInsuranceFundOccupiedFundDetailItem crmCreditInsuranceFundOccupiedFundDetailItem = new CrmCreditInsuranceFundOccupiedFundDetailItem();
//        crmCreditInsuranceFundOccupiedFundDetailItem.setOccupancyDate("2020-05-02");
//        crmCreditInsuranceFundOccupiedFundDetailItem.setSummary("3000");
//        crmCreditInsuranceFundOccupiedFundDetailItem.setOccupancyAmount("47651.9");
//        crmCreditInsuranceFundOccupiedFundDetailItem.setAmount("88888");
//        crmCreditInsuranceFundOccupiedFundDetailItems.add(crmCreditInsuranceFundOccupiedFundDetailItem);
        crmCreditInsuranceFundOccupiedFundItem.setCostList(crmCreditInsuranceFundOccupiedFundDetailItems);

        rsp.setCreditInsuranceFundOccupiedFund(crmCreditInsuranceFundOccupiedFundItem);

        CrmDistributionTrustBenefitsItem crmDistributionTrustBenefitsItem = new CrmDistributionTrustBenefitsItem();
        crmDistributionTrustBenefitsItem.setTotal("0.00");
        List<CrmDistributionTrustBenefitsDetailItem> crmDistributionTrustBenefitsDetailItems = new ArrayList<>();
//        CrmDistributionTrustBenefitsDetailItem crmDistributionTrustBenefitsDetailItem = new CrmDistributionTrustBenefitsDetailItem();
//        crmDistributionTrustBenefitsDetailItem.setMatchDate("2020-06-02");
//        crmDistributionTrustBenefitsDetailItem.setAssignmentType("1");
//        crmDistributionTrustBenefitsDetailItem.setAssignBeneficiaries("44444");
//        crmDistributionTrustBenefitsDetailItem.setSummaryTrustBenefits("33333");
//        crmDistributionTrustBenefitsDetailItem.setAllocationAmount("11111");
//        crmDistributionTrustBenefitsDetailItems.add(crmDistributionTrustBenefitsDetailItem);

        crmDistributionTrustBenefitsItem.setDistributionTrustBenefitsDetailList(crmDistributionTrustBenefitsDetailItems);

        rsp.setDistributionTrustBenefits(crmDistributionTrustBenefitsItem);

        CrmExpenditureItem crmExpenditureItem = new CrmExpenditureItem();
        crmExpenditureItem.setTotal("9,000,000.00");
        crmExpenditureItem.setAssetAllocation("9,000,000.00");
        crmExpenditureItem.setCreditInsuranceFundOccupation("0.00");
        crmExpenditureItem.setCost("0.00");
        crmExpenditureItem.setDistributionTrustBenefits("0.00");

        rsp.setExpenditureItem(crmExpenditureItem);

        CrmInitialAdditionalTrustPropertyItem crmInitialAdditionalTrustPropertyItem = new CrmInitialAdditionalTrustPropertyItem();
        crmInitialAdditionalTrustPropertyItem.setTotal("10,370,000.00");

        List<CrmInitialAdditionalTrustPropertyDetailItem> crmInitialAdditionalTrustPropertyDetailItems = new ArrayList<>();
        CrmInitialAdditionalTrustPropertyDetailItem crmInitialAdditionalTrustPropertyDetailItem1 = new CrmInitialAdditionalTrustPropertyDetailItem();
        crmInitialAdditionalTrustPropertyDetailItem1.setProject("初始信托财产");
        crmInitialAdditionalTrustPropertyDetailItem1.setPaymentDate("2017-12-27");
        crmInitialAdditionalTrustPropertyDetailItem1.setRemark("2017年度服务费； 新财道稳健增益8号基金");
        crmInitialAdditionalTrustPropertyDetailItem1.setAmount("1,000,000.00");
        crmInitialAdditionalTrustPropertyDetailItems.add(crmInitialAdditionalTrustPropertyDetailItem1);
        CrmInitialAdditionalTrustPropertyDetailItem crmInitialAdditionalTrustPropertyDetailItem2 = new CrmInitialAdditionalTrustPropertyDetailItem();
        crmInitialAdditionalTrustPropertyDetailItem2.setProject("追加信托财产");
        crmInitialAdditionalTrustPropertyDetailItem2.setPaymentDate("2018-01-27");
        crmInitialAdditionalTrustPropertyDetailItem2.setRemark("新财道稳健增益8号基金");
        crmInitialAdditionalTrustPropertyDetailItem2.setAmount("370,000.00");
        crmInitialAdditionalTrustPropertyDetailItems.add(crmInitialAdditionalTrustPropertyDetailItem2);
        CrmInitialAdditionalTrustPropertyDetailItem crmInitialAdditionalTrustPropertyDetailItem3 = new CrmInitialAdditionalTrustPropertyDetailItem();
        crmInitialAdditionalTrustPropertyDetailItem3.setProject("追加信托财产");
        crmInitialAdditionalTrustPropertyDetailItem3.setPaymentDate("2019-11-19");
        crmInitialAdditionalTrustPropertyDetailItem3.setRemark("第2次追加900万，600万用于途韩信托贷款，300万待配置");
        crmInitialAdditionalTrustPropertyDetailItem3.setAmount("9,000,000.00");
        crmInitialAdditionalTrustPropertyDetailItems.add(crmInitialAdditionalTrustPropertyDetailItem3);
        crmInitialAdditionalTrustPropertyItem.setInitialAdditionalTrustPropertyList(crmInitialAdditionalTrustPropertyDetailItems);

        rsp.setInitialAdditionalTrustProperty(crmInitialAdditionalTrustPropertyItem);

        CrmOtherItem crmOtherItem = new CrmOtherItem();
        crmOtherItem.setIncomeTotal("0.00");
        crmOtherItem.setExpenditureTotal("0.00");
        List<CrmOtherDetailItem> crmOtherDetailItems = new ArrayList<>();
//        CrmOtherDetailItem crmOtherDetailItem = new CrmOtherDetailItem();
//        crmOtherDetailItem.setRevenue("22222");
//        crmOtherDetailItem.setPaymentTypes("11111");
//        crmOtherDetailItem.setAmount("33333");
//        crmOtherDetailItem.setTime("2020-01-01");
//        crmOtherDetailItem.setRemark("44444");
//        crmOtherDetailItem.setOperate("55555");
//        crmOtherDetailItems.add(crmOtherDetailItem);
        crmOtherItem.setCostList(crmOtherDetailItems);

        rsp.setOther(crmOtherItem);

        CrmCostItem crmCostItem = new CrmCostItem();
        crmCostItem.setTotal("0.00");
        List<CrmCostDetailItem> crmCostDetailItems = new ArrayList<>();
        CrmCostDetailItem crmCostDetailItem = new CrmCostDetailItem();
        crmCostDetailItem.setDeadDate("");
        crmCostDetailItem.setSummary("保护人费用");
        crmCostDetailItem.setRemark("");
        crmCostDetailItem.setAmount("0.00");
        crmCostDetailItems.add(crmCostDetailItem);
        CrmCostDetailItem crmCostDetailItem2 = new CrmCostDetailItem();
        crmCostDetailItem2.setDeadDate("");
        crmCostDetailItem2.setSummary("受托人费用");
        crmCostDetailItem2.setRemark("");
        crmCostDetailItem2.setAmount("0.00");
        crmCostDetailItems.add(crmCostDetailItem2);
        CrmCostDetailItem crmCostDetailItem3 = new CrmCostDetailItem();
        crmCostDetailItem3.setDeadDate("");
        crmCostDetailItem3.setSummary("其他费用");
        crmCostDetailItem3.setRemark("");
        crmCostDetailItem3.setAmount("0.00");
        crmCostDetailItems.add(crmCostDetailItem3);

        crmCostItem.setCostList(crmCostDetailItems);

        rsp.setCost(crmCostItem);
        return  CommonResult.success(rsp);
    }
}
